<div ng-init="init();" class="kmi-layout-content myFavourite-content main">
    <div class="kmi-header-row" ng-class="{'disconection':disconnection,'aside-left':showSlight()}">
        <div class="kmi-side-btn left" ng-click="back();">
            <i class="material-icons">&#xE408;</i>
            <div class="kmi-can-click"></div>
        </div>
        <div class="brand-title">
            <div class="custom" ng-if="companyName">
                <div class="title" ng-bind="companyName"></div>
                <img src="" alt="" class="brand">
                <div class="gap"></div>
            </div>
            <div class="digiwin">
                <img src="image/smes_v340/logo_ch.png" alt="">
                <img src="image/smes_v340/logo_en.png" alt="">
            </div>
        </div>
        <div class="header-title" ng-bind="'myFavourite.title' | translate"></div>
    </div>
    <div class="kmi-layout-main-content">
        <div class="kmi-layout-page">
            <div class="empty-page" ng-if="!hasFavourite()">
                <div class="title" ng-bind="'myFavourite.hint' | translate"></div>
                <button class="add-btn" ng-click="editFavourite()">
                    <img src="image/smes_v340/favorite_add.png" alt="" class="icon-img">
                </button>
            </div>
            
            <div class="perfect-scrollbar">
                <div class="main-page" ng-if="hasFavourite()">
                
                    <div class="module-list">
                        <div class="module"
                            ng-repeat="module in menu | orderBy: 'order' | filter: isModuleHaveFavourite track by module.name"
                            ng-class="{'is-select' : selectModel == module.name, 'is-space': module.name == 'space'}">
                            <div class="module-title" ng-bind="module.title | translate"></div>

                            <div class="program-list">
                                <div class="program-component"
                                    ng-repeat="program in module.childs | orderBy: 'order' | filter: {isShow : true} track by program.name"
                                    ng-if="isFavourite(program)"
                                    ng-click="executeProgram(program)">
                                    <div class="icon menu">
                                        <!-- 20230310 modify by Alan for#129828 :  -->
                                        <img ng-src="{{ 'image/smes_v340/menu/' + program.icon + '.png' }}" alt="">
                                    </div>
                                    <div class="title" ng-bind="program.title | translate"></div>
                                    <div class="option" ng-click="openOptionDialog(program, $event)">
                                        <img src="image/smes_v340/option_icon.png" alt="">
                                    </div>
                                    <!-- 20220726 modify by Alan for#107965 : 配合規格進行調整 -->
                                    <div class="icon flag" ng-if="program.name === favouriteInfo.DefaultProgram"></div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
            
            <button class="edit-btn" ng-click="editFavourite()">
                <img src="image/smes_v340/favourite_edit.png" alt="" class="icon-img">
            </button>
        </div>
    </div>
</div>